package com.msos.dao.moreCredit;

import com.msos.model.moreCredit.MoreCredit;
import com.msos.utils.DBUtils;
import org.apache.commons.dbutils.QueryRunner;
import org.apache.commons.dbutils.handlers.BeanHandler;

import java.sql.SQLException;

public class MoreCreditDao {
    QueryRunner queryRunner = new QueryRunner(DBUtils.getDs());

    public MoreCredit getByMoreCredit(String morecredit) throws SQLException {
        return queryRunner.query("select * from customer where morecredit=?",new BeanHandler<>(MoreCredit.class),morecredit);
    }
}
